﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using ISSMoviePlex.DAL.Models;

namespace ISSMoviePlex.DAL.Repositories
{
    public class MemberStateRepository : BaseRepository<int, MemberState, MemberStateRepository>
    {
        public override MemberState FindById(int id)
        {
            return Context.MemberStates.SingleOrDefault(m => m.MemberStateId == id);
        }

        public MemberState GetMemberStateByName(string name)
        {
            return FindBy(m => m.MemberStateName == name).FirstOrDefault();
        }
    }
}
